<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateDingsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('dings', function (Blueprint $table) {
            $table->id();
            $table->string('name')->default('')->comment('应用名称');
            $table->string('corp_id')->default('')->comment('corpId');
            $table->string('app_key')->default('')->comment('应用AppKey');
            $table->string('app_secret')->default('')->comment('应用AppSecret');
            $table->string('token')->default('')->comment('事件与回调token');
            $table->string('aes_key')->default('')->comment('事件与回调aes_key');
            $table->string('robot_code')->default('')->comment('机器人编码');
            $table->timestamps();
            $table->softDeletes();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('dings');
    }
}
